/**
 * @author Salman Humdullah
 */
exports.GAIsoMetricConfigurations = Core.Class.singleton({

	classname : 'GAIsoMetricConfigurations',
	
	intialize : function() {
			this._patchImageWidth = null;
			this._patchImageHeight = null;
			this._GRID_SIZE = null;
			this._MAX_GRID_ROWS = null;
			this._patch_path = null;
			this._bg_path = null;
			this._ZOOM_IN_FACTOR = null;
			this._ZOOM_OUT_FACTOR = null;
			this._patchTransparency = null;
			this._cellWidthOffset = null;
			this._cellHeightOffset = null;
			this.USERLAYER_CELL_WIDTH = null;
			this.USERLAYER_CELL_HEIGHT = null;
			this.DIAMOND_LAYER_MARGIN_WIDTH = null;
			this.DIAMOND_LAYER_MARGIN_HEIGHT = null;

	},
	setGapiIsoMetricViewConfiguration : function (gridSize, gridRows,patchPath,bgPath, zoomInFactor,zoomOutFactor, patchTransparency, widthOffset, heightOffset, userLayerCellWidthNumerator, userLayerCellHeightNumerator, diamondLayerMarginWidth, diamondLayerMarginHeight){
//		this._patchImageWidth = patchWidth;
//		this._patchImageHeight = patchHeight;
		this._patchImageWidth = 128;
		this._patchImageHeight = 64;
		if(typeof userLayerCellWidthNumerator != 'undefined' && userLayerCellWidthNumerator != null){
			this.USERLAYER_CELL_WIDTH =  (userLayerCellWidthNumerator/(2*4));
		}else{
			this.USERLAYER_CELL_WIDTH =  (123/(2*4));
		}
		
		if(typeof userLayerCellHeightNumerator != 'undefined' && userLayerCellHeightNumerator != null){
			this.USERLAYER_CELL_HEIGHT = (userLayerCellHeightNumerator/(2*4)); //32
		}else{
			this.USERLAYER_CELL_HEIGHT = (63/(2*4)); //32
		}
		
		if(typeof diamondLayerMarginWidth != 'undefined' && diamondLayerMarginWidth != null){
			this.DIAMOND_LAYER_MARGIN_WIDTH = diamondLayerMarginWidth;
		}else{
			this.DIAMOND_LAYER_MARGIN_WIDTH = 600;
		}
		
		if(typeof diamondLayerMarginHeight != 'undefined' && diamondLayerMarginHeight != null){
			this.DIAMOND_LAYER_MARGIN_HEIGHT = diamondLayerMarginHeight;
		}else{
			this.DIAMOND_LAYER_MARGIN_HEIGHT = 600;
		}
//		this.USERLAYER_CELL_WIDTH =  (120/(2*4));
//		this.USERLAYER_CELL_HEIGHT = (55/(2*4)); //32
//		this.DIAMOND_LAYER_MARGIN_WIDTH = 700;
//		this.DIAMOND_LAYER_MARGIN_HEIGHT = 750;

		
		gridSize.setX(gridSize.getX() * 4);
		gridSize.setY(gridSize.getY() * 4);
		
		this._GRID_SIZE = gridSize;
		
		this._MAX_GRID_ROWS = (gridRows * 4);
		this._patch_path = patchPath;
		this._bg_path = bgPath;
		this._ZOOM_IN_FACTOR = zoomInFactor;
		this._ZOOM_OUT_FACTOR = zoomOutFactor;
		this._patchTransparency = patchTransparency;
		this._cellWidthOffset = widthOffset;
		this._cellHeightOffset = heightOffset;
//		console.log("---===Log: setGapiIsoMetricViewConfiguration : iW" + 		this._patchImageWidth +
//		this._patchImageHeight +		this._GRID_SIZE +  this._MAX_GRID_ROWS +
//		this._patch_path + this._bg_path +  this._ZOOM_IN_FACTOR + this._ZOOM_OUT_FACTOR);

	},
	getPatchWidth: function (){
		return this._patchImageWidth;
	},
	setPatchWidth: function (patchWidth){
		this._patchImageWidth = patchWidth;
	},
	getPatchHeight: function (){
		return this._patchImageHeight;
	},
	setPatchHeight: function (patchHeight){
		this._patchImageHeight = patchHeight;
	},
	getGridSize: function (){
		return this._GRID_SIZE;
	},
	setGridSize: function (size){
		this._GRID_SIZE = size;
	},	
	getMaxGridRows: function (){
		return this._MAX_GRID_ROWS;
	},
	getPatchPath: function (){
		return this._patch_path;
	},
	getBgPath: function (){
		return this._bg_path;
	},
	getZoomInFactor: function (){
		return this._ZOOM_IN_FACTOR;
	},
	getZoomOutFactor: function (){
		return this._ZOOM_OUT_FACTOR;
	},
	getPatchTransparency : function (){
		return this._patchTransparency;
	},
	getCellWidthOffset : function(){
		return this._cellWidthOffset;
	},
	getCellHeightOffset : function() {
		return this._cellHeightOffset;
	},
	destroy : function(){
		this._patchImageWidth = null;
		this._patchImageHeight = null;
		this._GRID_SIZE = null;
		this._MAX_GRID_ROWS = null;
		this._patch_path = null;
		this._bg_path = null;
		this._ZOOM_IN_FACTOR = null;
		this._ZOOM_OUT_FACTOR = null;
		this._patchTransparency = null;
		this._cellWidthOffset = null;
		this._cellHeightOffset = null;

	}
});